<template>
  <div class="heritage-protection-container">
    <div class="page-header">
      <h1 class="page-title">文化遗产保护意识</h1>
      <p class="page-description">了解北京文化遗产保护现状，提高文物保护意识</p>
    </div>

    <div class="heritage-status-section">
      <el-card class="status-card">
        <template #header>
          <div class="card-header">
            <h2>北京文化遗产保护状况</h2>
          </div>
        </template>
        
        <div class="status-content">
          <div class="status-chart">
            <div class="chart-placeholder">
              <el-icon><DataAnalysis /></el-icon>
              <p>文物保护状况统计图表</p>
            </div>
          </div>
          
          <div class="status-info">
            <h3>文物保护现状概览</h3>
            <p>北京作为中国历史文化名城，拥有丰富的文化遗产资源。目前，全市共有不可移动文物点3840处，其中全国重点文物保护单位98处，市级文物保护单位357处。</p>
            <p>近年来，北京市加大了对文物保护的投入，但仍面临城市化进程中的保护挑战。</p>
            
            <el-button type="primary" class="beijing-button">查看详细报告</el-button>
          </div>
        </div>
      </el-card>
    </div>

    <div class="protection-initiatives">
      <h2 class="section-title">保护举措</h2>
      
      <div class="initiatives-grid">
        <el-card class="initiative-card" shadow="hover">
          <div class="initiative-icon">
            <el-icon><Document /></el-icon>
          </div>
          <h3>法律法规</h3>
          <p>了解北京市文物保护相关法律法规</p>
          <el-button type="text" class="learn-more-btn">了解更多</el-button>
        </el-card>
        
        <el-card class="initiative-card" shadow="hover">
          <div class="initiative-icon">
            <el-icon><Monitor /></el-icon>
          </div>
          <h3>科技保护</h3>
          <p>探索文物保护中的科技应用</p>
          <el-button type="text" class="learn-more-btn">了解更多</el-button>
        </el-card>
        
        <el-card class="initiative-card" shadow="hover">
          <div class="initiative-icon">
            <el-icon><User /></el-icon>
          </div>
          <h3>公众参与</h3>
          <p>公众如何参与文物保护工作</p>
          <el-button type="text" class="learn-more-btn">了解更多</el-button>
        </el-card>
        
        <el-card class="initiative-card" shadow="hover">
          <div class="initiative-icon">
            <el-icon><School /></el-icon>
          </div>
          <h3>教育宣传</h3>
          <p>文物保护教育与宣传活动</p>
          <el-button type="text" class="learn-more-btn">了解更多</el-button>
        </el-card>
      </div>
    </div>

    <div class="case-studies">
      <h2 class="section-title">保护案例</h2>
      
      <el-carousel :interval="4000" type="card" height="400px">
        <el-carousel-item v-for="item in 4" :key="item">
          <div class="case-study-card">
            <div class="case-image">
              <div class="image-placeholder">案例图片 {{ item }}</div>
            </div>
            <div class="case-info">
              <h3>文物保护案例 {{ item }}</h3>
              <p>这里是北京某处文物保护的成功案例描述，展示了保护前后的对比以及采取的保护措施。</p>
            </div>
          </div>
        </el-carousel-item>
      </el-carousel>
    </div>
  </div>
</template>

<script setup lang="ts">
import { DataAnalysis, Document, Monitor, User, School } from '@element-plus/icons-vue'
</script>

<style scoped>
.heritage-protection-container {
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.page-header {
  text-align: center;
  margin-bottom: 40px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.page-title {
  font-size: 32px;
  color: #c62f2f;
  margin-bottom: 10px;
  font-weight: bold;
}

.page-description {
  font-size: 16px;
  color: #666;
  max-width: 600px;
  margin: 0 auto;
}

.heritage-status-section {
  margin-bottom: 50px;
}

.status-card {
  border: none;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.card-header h2 {
  margin: 0;
  font-size: 22px;
  color: #c62f2f;
}

.status-content {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
}

.status-chart {
  flex: 1;
  min-width: 300px;
}

.chart-placeholder {
  height: 300px;
  background-color: #f5f7fa;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: #909399;
}

.chart-placeholder .el-icon {
  font-size: 48px;
  margin-bottom: 10px;
}

.status-info {
  flex: 1;
  min-width: 300px;
}

.status-info h3 {
  font-size: 20px;
  color: #333;
  margin-bottom: 15px;
}

.status-info p {
  color: #666;
  line-height: 1.6;
  margin-bottom: 15px;
}

.beijing-button {
  background-color: #c62f2f;
  border-color: #c62f2f;
  padding: 12px 24px;
  font-size: 16px;
  margin-top: 15px;
}

.beijing-button:hover {
  background-color: #a52222;
  border-color: #a52222;
}

.section-title {
  font-size: 24px;
  color: #333;
  margin-bottom: 30px;
  text-align: center;
}

.initiatives-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 50px;
}

.initiative-card {
  padding: 30px 20px;
  text-align: center;
  transition: transform 0.3s;
  height: 100%;
}

.initiative-card:hover {
  transform: translateY(-5px);
}

.initiative-icon {
  font-size: 40px;
  color: #c62f2f;
  margin-bottom: 15px;
}

.initiative-card h3 {
  font-size: 18px;
  color: #333;
  margin-bottom: 10px;
}

.initiative-card p {
  color: #666;
  font-size: 14px;
  margin-bottom: 15px;
}

.learn-more-btn {
  color: #c62f2f;
}

.learn-more-btn:hover {
  color: #a52222;
}

.case-studies {
  margin-bottom: 50px;
}

.case-study-card {
  height: 100%;
  background-color: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.case-image {
  height: 250px;
  background-color: #f5f7fa;
}

.image-placeholder {
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #909399;
  font-size: 18px;
}

.case-info {
  padding: 20px;
}

.case-info h3 {
  font-size: 18px;
  color: #333;
  margin-bottom: 10px;
}

.case-info p {
  color: #666;
  line-height: 1.6;
}
</style>
